<template>
    <div class="globalModel">
         <div class="md-modal modal-msg md-modal-transition" v-bind:class="{'md-show':gMtwo}">
            <div class="md-modal-inner">
                <div class="md-top">
                    <button class="md-close" @click="mdClose">Close</button>
                </div>
                <div class="md-content">
                    <div class="confirm-tips">
                        <slot name="message"></slot>
                    </div>
                </div>
                <div class="login-wrap">
                    <slot name="modelBtn"></slot>
                </div>
              </div>
            </div>
         <div class="md-overlay" v-if="gMtwo" @click="mdClose"></div>

         <div class="md-modal modal-msg md-modal-transition" v-bind:class="{'md-show':gMone}">
            <div class="md-modal-inner">
                <div class="md-top">
                    <button class="md-close" @click="postMsg">Close</button>
                </div>
                <div class="md-content">
                    <div class="confirm-tips">
                        <slot name="messageOne"></slot>
                    </div>
                </div>
                <div class="login-wrap">
                    <slot name="modelBtnOne"></slot>
                </div>
              </div>
            </div>
         <div class="md-overlay" v-if="gMone" @click="postMsg"></div>

         <div class="md-modal modal-msg md-modal-transition" v-bind:class="{'md-show':modalConfirm}">
            <div class="md-modal-inner">
                <div class="md-top">
                    <button class="md-close" @click="delClose">Close</button>
                </div>
                <div class="md-content">
                    <div class="confirm-tips">
                        <slot name="messageThree"></slot>
                    </div>
                </div>
                <div class="login-wrap">
                    <slot name="modelBtnThree"></slot>
                </div>
              </div>
            </div>
         <div class="md-overlay" v-if="modalConfirm" @click="delClose"></div>

         <div class="md-modal modal-msg md-modal-transition" v-bind:class="{'md-show':DelAddress}">
            <div class="md-modal-inner">
                <div class="md-top">
                    <button class="md-close" @click="AddressClose">Close</button>
                </div>
                <div class="md-content">
                    <div class="confirm-tips">
                        <slot name="messageFour"></slot>
                    </div>
                </div>
                <div class="login-wrap">
                    <slot name="modelBtnFour"></slot>
                </div>
            </div>
        </div>
         <div class="md-overlay" v-if="DelAddress" @click="AddressClose"></div>  
    </div>
</template>

<script>
 export default {
    props: ['gMtwo','gMone','modalConfirm','DelAddress'],
    data() {
        return {

        }
    },
    components: {

    },
    mounted () {
    },
    methods: {
        mdClose(){
            this.$emit('fromCartList',false)
        },
        postMsg(){
            this.$emit('fromShowMsg',false)
        },
        delClose(){
            this.$emit('fromDelMsg',false)
        },
        AddressClose(){
            this.$emit('fromDelAddress',false)
        }
            
    }
 }
</script>
<style scoped>
.login-wrap{
    text-align: center;
}
</style>
